package com.riven.bilibilidemo.activity;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.FragmentActivity;

import com.riven.bilibilidemo.utils.LogUtil;

import butterknife.ButterKnife;

/**
 * @author rivenlee
 * @date 2017/3/8 20:39
 * Activity基类
 */

public abstract class BaseActivity extends FragmentActivity {

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView();
        initViews();
        initData();
        ButterKnife.bind(this);
    }

    protected abstract void setContentView();

    public LogUtil getLog(){
        LogUtil logUtil = LogUtil.newInstance();
        return logUtil;
    }

    protected abstract void initData();
    protected abstract void initViews();
}
